/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.unice.miage.oobdoo.api;

import com.unice.miage.oobdoo.entity.Album;
import com.unice.miage.oobdoo.manager.AlbumManager;
import java.util.ArrayList;
import java.util.Collection;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.ejb.EJB;
import javax.ejb.Stateless;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;

/**
 *
 * @author remi
 */
@Stateless
@Path("/album")
public class AlbumFacadeREST{
    @EJB
    private AlbumManager albumManager;
   
    /*
    @GET
    @Path("public")
    @Produces("application/json")
    public JSONObject publicList()
    {
        Collection<Album> lstAlbums = albumManager.getAllAlbumsPublic();
        System.out.println("## sizeof lstAlbums : "+lstAlbums.size());
        JSONObject objroot = new JSONObject();
        for(Album c: lstAlbums)
        {
            try {
                objroot.accumulate("albums", c.getNom());
            } catch (JSONException ex) {
                Logger.getLogger(AlbumFacadeREST.class.getName()).log(Level.SEVERE, null, ex);
            }
        }
        
        return objroot;
    }*/


    
    
}
